using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.SceneManagement;

public class WinPanel : BasePanel<WinPanel>
{

    public CustomGUIButton yesButton;
    public CustomGUIInput input;
    void Start()
    {
        yesButton.clickEvent += () =>
        {
            //取消暂停
            Time.timeScale = 1;
            //增加排行记录
            GameDataMgr.Instance.AddRankInfo(new RankInfo(input.content.text,
            GamePanel.Instance.nowScore,
             GamePanel.Instance.nowTime));
            //加载开始场景
            HideMe();
            SceneManager.LoadScene("BeginScene");
        };
        HideMe();
    }
}
